In recent years, a resistive RAM (ReRAM) has attracted much attention for the application to the next generation non-volatile semiconductor memory. In ReRAM, the resistance values of the variable resistance film are controlled by applying voltage pulse so that the two different resistance states are realized. Since these two different resistance states are kept even after removing the electrical bias, ReRAM can be act as a non-volatile memory.
Among the various candidates of the variable resistance films for ReRAM, it seems that some materials have the favorable resistance values; some are difficult to change the low resistance states to the high resistance states, and some are difficult to change the high resistance state to the low resistance states. Since changing the resistance states correspond to the data program or the data erase in the ReRAM, the difficulty in changing the resistance states causes to the error in the data program or the data erase operations. Thus, in order to improve the reliability of ReRAM, error in the data program and/or data erase should be suppressed, and if occurred, the error should be compensated.
For example, the following method is also considered: when the writing or erasing of data does not succeed within a predetermined number of times, the writing or erasing of data to or from the memory cell is abandoned and data is corrected using the error correcting code (ECC) which has been used during a data reading (decoding) operation. However, an ECC with an error correction capability more than that in the related art is needed in order to correct a data inversion error which occurs when the written or erased data is stored and an error which occurs when data is written or erased. In general, in order to improve the error correction capability of the ECC, a large amount of parity data is stored separately from data which is desired to be stored such that errors can be corrected. However, when the amount of parity data increases, effective storage capacity for storing data which is desired to be stored is reduced, which is not preferable.
Therefore, in the ReRAM in which the resistance variable film which is less likely to be changed from the low resistance state to the high resistance state or from the high resistance state to the low resistance state is used in the memory cell, the problem is to prevent an increase in the amount of parity data while achieving error correction capability higher than that in the related art to correct errors which occur when data is written or erased.